package com.shsoft.common;

/**
 * 常量类
 */
public class Constant {
    // 灯珠个数
    public static final int LIGHT_COUNT = 20;
    // 预设颜色个数
    public static final int COLOR_COUNT = 20;

    // 蓝牙请求码
    public static final int BLUETOOTH_REQUEST_CODE = 1;

    // 蓝牙权限申请码
    public static final int BLUETOOTH_PERMISSION_CODE = 1;

    // 蓝牙设备esp32c3的名称
    public static final String BLE_NAME = "ColorfulCC";

    // 蓝牙服务的UUID
    public static final String SERVICE_UUID = "fcc2a149-edc6-8255-e8eb-848537660235";
    // I2C设备在线离线的特征
    public static final String I2C_ONLINE_CHARACTERISTIC_UUID = "2a303736-4728-08df-3ce4-59b1f45c3c83";
    // 数据发送结果的特征
    public static final String TRANSFER_RESULT_CHARACTERISTIC_UUID = "e5ff56f6-a39f-ea82-f77f-e53b8d8cbc57";
    // 展板新的显示信息特征
    public static final String I2C_NEW_INFO_CHARACTERISTIC_UUID = "854300e6-0ecb-4699-a7a8-5098b9ef7f9c";

    // I2C设备在线离线
    public static final String I2C_OFFLINE = "offline";
    public static final String I2C_ONLINE = "online";

    // 颜色模式
    public static final int COLOR_MODE_SINGLE = 1;
    public static final int COLOR_MODE_MIX = 2;

    // 亮灯模式
    public static final int LIGHT_MODE_LONG = 1;
    public static final int LIGHT_MODE_HORSE = 2;
    public static final int LIGHT_MODE_FLOWING_WATER = 3;
    public static final int LIGHT_MODE_BREATHING = 4;
    public static final int LIGHT_MODE_COMPOSITE = 5;

    // 顺时针、逆时针
    public static final int CLOCKWISE = 1;
    public static final int ANTICLOCKWISE = 2;

    // 呼吸灯模式
    public static final int BREATHING_MODE_D_L_D = 1; // 暗→明→暗
    public static final int BREATHING_MODE_L_D_L = 2; // 明→暗→明
    public static final int BREATHING_MODE_L_D = 3; // 明→暗
    public static final int BREATHING_MODE_D_L= 4; // 暗→明

    // 流水灯模式
    public static final int FLOWINGWATER_MODE_TAIL_FOLLOW = 1; // 尾部跟进
    public static final int FLOWINGWATER_MODE_HEAD_BACK = 2; // 头部回退
    public static final int FLOWINGWATER_MODE_FULL_FINISH = 3; // 灯满结束

    // 复合模式总计可用的字节数
    public static final int TOTAL_BYTE_COUNT = 440;

    // 预设颜色黑色阈值
    public static final int BLACK_VALUE = 55;
}
